﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

using Microsoft.Exchange.WebServices.Data;

namespace EWSEditor.Common
{
    public struct ResponseCodeInfo
    {
        private string message;
        public string Message
        {
            get
            {
                return message;
            }
        }

        private string comments;
        public string Comments
        {
            get
            {
                return comments;
            }
        }

        public ResponseCodeInfo(string message, string comments)
        {
            this.message = message;
            this.comments = comments;
        }
    }

    /// <summary>
    /// Imported data from the Inside Exchange Web Services book, provides more detailed
    /// information about some of the ServieError response codes returned by EWS.  This class
    /// contains a dictionary look up for the messages by error code.
    /// </summary>
    public class ResponseCodeHelper
    {
        #region Singleton Members
        // Single instance
        private static ResponseCodeHelper ThisInstance = null;

        // Private constructor
        private ResponseCodeHelper() { }

        public static ResponseCodeHelper Instance()
        {
            if (ThisInstance == null)
            {
                ThisInstance = new ResponseCodeHelper();
            }

            return ThisInstance;
        }
        #endregion

        Dictionary<ServiceError, ResponseCodeInfo> ResponseCodeDictionary = new Dictionary<ServiceError, ResponseCodeInfo>();

        public ResponseCodeInfo? GetResponseCodeInfo(ServiceError code)
        {
            if (this.ResponseCodeDictionary.Count == 0) { this.InitializeList(); }

            return (ResponseCodeInfo?)this.ResponseCodeDictionary[code];
        }

        #region Dictionary Initialization

        private void InitializeList()
        {
            this.ResponseCodeDictionary.Add(ServiceError.NoError, new ResponseCodeInfo("None", "Represents a successful operation. This is a good thing."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorAccessDenied, new ResponseCodeInfo("Access is denied. Check credentials and try again.", "Calling account does not have the rights to perform the action requested."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorAccountDisabled, new ResponseCodeInfo("Account is disabled. Contact the account administrator.", "Returned when the account in question has been disabled."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorAddDelegatesFailed, new ResponseCodeInfo("", ""));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorADOperation, new ResponseCodeInfo("Active Directory operation did not succeed. Try again later.", "Operation failed due to issues talking with the Active Directory."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorADSessionFilter, new ResponseCodeInfo("Invalid search criteria.", "You should never encounter this response code, which occurs only as aresult of an issue in Exchange Web Services."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorADUnavailable, new ResponseCodeInfo("Active Directory is unavailable. Try again later.", "The Active Directory is temporarily unavailable. Try your request againlater."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorAffectedTaskOccurrencesRequired, new ResponseCodeInfo("AffectedTaskOccurrences attribute is required for Task items.", "The AffectedTaskOccurrences enumeration value is missing. It is requiredwhen deleting a task so that Exchange Web Services knows whether youwant to delete a single task or all occurrences of a repeating task."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorAttachmentSizeLimitExceeded, new ResponseCodeInfo("The file attachment exceeds the maximum supported size.", "You encounter this error only if the size of your attachment exceeds Int32.MaxValue (in bytes). Of course, you probably have bigger problems if thatis the case.Appendix A Response CodesAppendix A Response CodesErrorAvailabilityConfigNotFoundMessage Configuration information for the current forest or domain was not foundin the Active Directory.Applicable methods GetUserAvailabilityThe availability configuration information for the local Active Directoryforest is missing from the Active Directory."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorBatchProcessingStopped, new ResponseCodeInfo("Item was not processed as a result of a previous error.", "Indicates that the previous item in the request failed in such a way thatExchange Web Services stopped processing the remaining items in therequest. All remaining items are marked with ErrorBatchProcessingStopped."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorCalendarCannotMoveOrCopyOccurrence, new ResponseCodeInfo("Cannot move or copy a calendar occurrence.", "You are not allowed to move or copy calendar item occurrences."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorCalendarCannotUpdateDeletedItem, new ResponseCodeInfo("Cannot update calendar item that has already been deleted.", "If the update in question would send out a meeting update, but the meetingis in the organizer's deleted items folder, then you encounter this error."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorCalendarCannotUseIdForOccurrenceId, new ResponseCodeInfo("The Id specified does not represent an occurrence.", "When a RecurringMasterId is examined, the OccurrenceId attribute isexamined to see if it refers to a valid occurrence. If it doesn't, then this responsecode is returned."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorCalendarCannotUseIdForRecurringMasterId, new ResponseCodeInfo("The specified Id does not represent a recurring master item.", "When an OccurrenceId is examined, the RecurringMasterId attribute is examinedto see if it refers to a valid recurring master. If it doesn't, then thisresponse code is returned.Appendix A Response CodesAppendix A Response CodesErrorCalendarDurationIsTooLongMessage Calendar item duration is too long.Applicable methods CreateItem, UpdateItemReturned if the suggested duration of a calendar item exceeds five years."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorCalendarDurationIsTooLong, new ResponseCodeInfo("Calendar item duration is too long.", "Returned if the suggested duration of a calendar item exceeds five years."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorCalendarEndDateIsEarlierThanStartDate, new ResponseCodeInfo("EndDate is earlier than StartDate.", "The end date must be greater than the start date. Otherwise, it isn't worthhaving the meeting."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorCalendarFolderIsInvalidForCalendarView, new ResponseCodeInfo("Cannot request CalendarView for the folder.", "You can apply calendar paging only on a CalendarFolder."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorCalendarInvalidAttributeValue, new ResponseCodeInfo("Attribute has an invalid value.", "You should never encounter this response code."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorCalendarInvalidDayForTimeChangePattern, new ResponseCodeInfo("The value of the DaysOfWeek property is not valid for time change patternof time zone.", "When defining a time change pattern, the values Day, WeekDay andWeekendDay are invalid."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorCalendarInvalidDayForWeeklyRecurrence, new ResponseCodeInfo("The value of the DaysOfWeek property is invalid for a weekly recurrence.", "When defining a weekly recurring pattern, the values Day, Weekday, andWeekendDay are invalid.Appendix A Response CodesAppendix A Response CodesErrorCalendarInvalidPropertyStateMessage The property has invalid state.Applicable methods GetItemIndicates that the state of the calendar item recurrence blob in theExchange Store is invalid."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorCalendarInvalidPropertyState, new ResponseCodeInfo("The property has invalid state.", "Indicates that the state of the calendar item recurrence blob in theExchange Store is invalid."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorCalendarInvalidPropertyValue, new ResponseCodeInfo("The property has an invalid value.", "You should never encounter this response code."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorCalendarInvalidRecurrence, new ResponseCodeInfo("The recurrence is invalid.", "You should never encounter this response code. It indicates that the internalstructure of the objects representing the recurrence is invalid."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorCalendarInvalidTimeZone, new ResponseCodeInfo("TimeZone is invalid.", "Occurs when an invalid time zone is encountered."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorCalendarIsCancelledForAccept, new ResponseCodeInfo("", ""));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorCalendarIsCancelledForDecline, new ResponseCodeInfo("", ""));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorCalendarIsCancelledForRemove, new ResponseCodeInfo("", ""));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorCalendarIsCancelledForTentative, new ResponseCodeInfo("", ""));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorCalendarIsDelegatedForAccept, new ResponseCodeInfo("AcceptItem action is invalid for a delegated meeting message.", "Accepting a meeting request by using delegate access is not supported inRTM."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorCalendarIsDelegatedForDecline, new ResponseCodeInfo("DeclineItem operation is invalid for a delegated meeting message.", "Declining a meeting request by using delegate access is not supported inRTM.Appendix A Response CodesAppendix A Response CodesErrorCalendarIsDelegatedForRemoveMessage RemoveItem action is invalid for a delegated meeting message.Applicable methods CreateItem with a RemoveItem response objectRemoving an item from the calendar by using delegate access is not supportedin RTM."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorCalendarIsDelegatedForRemove, new ResponseCodeInfo("RemoveItem action is invalid for a delegated meeting message.", "Removing an item from the calendar by using delegate access is not supportedin RTM."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorCalendarIsDelegatedForTentative, new ResponseCodeInfo("TentativelyAcceptItem action is invalid for a delegated meeting message.", "Tentatively accepting a meeting request by using delegate access is notsupported in RTM."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorCalendarIsNotOrganizer, new ResponseCodeInfo("User must be an organizer for CancelCalendarItem action.", "Only the meeting organizer can cancel the meeting, no matter how muchyou are dreading it."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorCalendarIsOrganizerForAccept, new ResponseCodeInfo("The user is the organizer of this meeting, and cannot, therefore, accept it.", "The organizer cannot accept the meeting. Only attendees can accept ameeting request."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorCalendarIsOrganizerForDecline, new ResponseCodeInfo("The user is the organizer of this meeting, and cannot, therefore, decline it.", "The organizer cannot decline the meeting. Only attendees can decline ameeting request."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorCalendarIsOrganizerForRemove, new ResponseCodeInfo("The user is the organizer of this meeting, and cannot, therefore, remove it.", "The organizer cannot remove the meeting from the calendar by usingRemoveItem. The organizer can do this only by cancelling the meeting request.Only attendees can remove a calendar item.Appendix A Response CodesAppendix A Response CodesErrorCalendarIsOrganizerForTentativeMessage The user is the organizer of this meeting, and cannot, therefore, tentativelyaccept it.Applicable methods CreateItem with a TentativelyAcceptItem response objectThe organizer cannot tentatively accept the meeting request. Only attendeescan tentatively accept a meeting request."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorCalendarIsOrganizerForTentative, new ResponseCodeInfo("The user is the organizer of this meeting, and cannot, therefore, tentativelyaccept it.", "The organizer cannot tentatively accept the meeting request. Only attendeescan tentatively accept a meeting request."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorCalendarOccurrenceIndexIsOutOfRecurrenceRange, new ResponseCodeInfo("Occurrence index is out of recurrence range.", "Occurs when the occurrence index specified in the OccurenceId does notcorrespond to a valid occurrence. For instance, if your recurrence patterndefines a set of three meeting occurrences, and you try to access the fifthoccurrence, well, there is no fifth occurrence. So instead, you get this responsecode."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorCalendarOccurrenceIsDeletedFromRecurrence, new ResponseCodeInfo("Occurrence with this index was previously deleted from the recurrence.", "Occurs when the occurrence index specified in the OccurrenceId correspondsto a deleted occurrence."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorCalendarOutOfRange, new ResponseCodeInfo("The calendar property falls out of valid range.", "Occurs when a recurrence pattern is defined that contains values formonth, day, week, and so on that are out of range. For example, specifyingthe fifteenth week of the month is both silly and an error."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorCalendarMeetingRequestIsOutOfDate, new ResponseCodeInfo("", ""));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorCalendarViewRangeTooBig, new ResponseCodeInfo("The specified view range exceeds the maximum range of two years.", "Calendar paging can span a maximum of two years.Appendix A Response CodesAppendix A Response CodesErrorCannotCreateCalendarItemInNonCalendarFolderMessage Cannot create a calendar item in a non-calendar folder.Applicable methods CreateItemCalendar items can be created only within calendar folders."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorCallerIsInvalidADAccount, new ResponseCodeInfo("", ""));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorCannotCreateCalendarItemInNonCalendarFolder, new ResponseCodeInfo("Cannot create a calendar item in a non-calendar folder.", "Calendar items can be created only within calendar folders."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorCannotCreateContactInNonContactFolder, new ResponseCodeInfo("", ""));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorCannotCreatePostItemInNonMailFolder, new ResponseCodeInfo("", ""));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorCannotCreateTaskInNonTaskFolder, new ResponseCodeInfo("Cannot create a task in a non-task Folder.", "Tasks can be created only within Task folders."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorCannotDeleteObject, new ResponseCodeInfo("Object cannot be deleted.", "Occurs when Exchange Web Services fails to delete the item or folder inquestion for some unexpected reason."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorCannotDeleteTaskOccurrence, new ResponseCodeInfo("Deleting a task occurrence is not permitted on non-recurring tasks, on thelast occurrence of a recurring task or on a regenerating task.", "This error indicates that you either tried to delete an occurrence of a nonrecurringtask or tried to delete the last occurrence of a recurring task."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorCannotOpenFileAttachment, new ResponseCodeInfo("The attachment could not be opened.", "Exchange Web Services could not open the file attachmentAppendix A Response CodesAppendix A Response CodesErrorCannotUseFolderIdForItemIdMessage Expected an item Id but received a folder Id.Applicable methods All item methods that take an ItemIdThe Id that was passed represents a folder rather than an item"));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorCannotSetCalendarPermissionOnNonCalendarFolder, new ResponseCodeInfo("", ""));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorCannotSetNonCalendarPermissionOnCalendarFolder, new ResponseCodeInfo("", ""));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorCannotSetPermissionUnknownEntries, new ResponseCodeInfo("", ""));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorCannotUseFolderIdForItemId, new ResponseCodeInfo("Expected an item Id but received a folder Id.", "The Id that was passed represents a folder rather than an item"));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorCannotUseItemIdForFolderId, new ResponseCodeInfo("", ""));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorChangeKeyRequired, new ResponseCodeInfo("ChangeKey is required if overriding automatic conflict resolution.", "You will never encounter this response code. Superceded byErrorChangeKeyRequiredForWriteOperations."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorChangeKeyRequiredForWriteOperations, new ResponseCodeInfo("ChangeKey is required for this operation.", "When performing certain update operations, you must provide a validchange key."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorConnectionFailed, new ResponseCodeInfo("Connection did not succeed. Try again later.", "This response code is returned when Exchange Web Services is unable toconnect to the Mailbox in question."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorContainsFilterWrongType, new ResponseCodeInfo("", ""));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorContentConversionFailed, new ResponseCodeInfo("Content conversion failed.", "Occurs when Exchange Web Services is unable to retrieve the MIME contentfor the item in question (GetItem), or is unable to create the item fromthe supplied MIME content (CreateItem).Appendix A Response CodesAppendix A Response CodesErrorCorruptDataMessage Data is corrupt.Applicable methods All methodsIndicates that the data in question is corrupt and cannot be acted upon."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorCorruptData, new ResponseCodeInfo("Data is corrupt.", "Indicates that the data in question is corrupt and cannot be acted upon."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorCreateItemAccessDenied, new ResponseCodeInfo("Unable to create item. The user account does not have the right to createitems.", "Indicates that the caller does not have the right to create the item in question."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorCreateSubfolderAccessDenied, new ResponseCodeInfo("Unable to create subfolder. The user account does not have the right tocreate subfolders.", "The calling account does not have the proper rights to create the sub-folder in question."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorCrossMailboxMoveCopy, new ResponseCodeInfo("Move and Copy operations across mailbox boundaries are not permitted.", "You cannot move an item or folder from one Mailbox to another."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorDataSizeLimitExceeded, new ResponseCodeInfo("Property exceeds the maximum supported size.", "Either the data that you were trying to set exceeded the maximum size forthe property, or the value is large enough to require streaming and theproperty does not support streaming (that is, folder properties).Appendix A Response CodesAppendix A Response CodesErrorDataSourceOperationMessage Invalid data source operation.Applicable methods All methodsAn Active Directory operation failed."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorDataSourceOperation, new ResponseCodeInfo("Invalid data source operation.", "An Active Directory operation failed."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorDelegateAlreadyExists, new ResponseCodeInfo("", ""));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorDelegateCannotAddOwner, new ResponseCodeInfo("", ""));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorDelegateMissingConfiguration, new ResponseCodeInfo("", ""));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorDelegateNoUser, new ResponseCodeInfo("", ""));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorDelegateValidationFailed, new ResponseCodeInfo("", ""));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorDeleteDistinguishedFolder, new ResponseCodeInfo("Distinguished folders cannot be deleted.", "You cannot delete a distinguished folder"));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorDeleteItemsFailed, new ResponseCodeInfo("The deletion failed.", "You will never encounter this response code."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorDistinguishedUserNotSupported, new ResponseCodeInfo("", ""));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorDistributionListMemberNotExist, new ResponseCodeInfo("", ""));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorDuplicateInputFolderNames, new ResponseCodeInfo("The specified list of managed folder names contains duplicate entries.", "There are duplicate values in the folder names array that was passed intoCreateManagedFolder."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorDuplicateUserIdsSpecified, new ResponseCodeInfo("", ""));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorInvalidManagedFolderProperty, new ResponseCodeInfo("The Managed Folder property is corrupt or otherwise invalid.", "Indicates that the structure of the managed folder is corrupt and cannotbe rendered."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorMissingManagedFolderId, new ResponseCodeInfo("The managed folder Id is missing.", "The policy ids property (Property Tag: 0x6732, String) for the folder inquestion is missing. You should consider this a corrupt folder."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorInvalidArgument, new ResponseCodeInfo("", ""));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorInvalidMailbox, new ResponseCodeInfo("", ""));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorInvalidManagedFolderQuota, new ResponseCodeInfo("The managed folder has an invalid quota.", "Indicates that the quota that is set on the managed folder is less than zero,indicating a corrupt managed folder."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorInvalidManagedFolderSize, new ResponseCodeInfo("The managed folder has an invalid storage limit value.", "Indicates that the size that is set on the managed folder is less than zero,indicating a corrupt managed folder."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorInvalidPermissionSettings, new ResponseCodeInfo("", ""));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorInvalidProxySecurityContext, new ResponseCodeInfo("", ""));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorInvalidUserInfo, new ResponseCodeInfo("", ""));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorManagedFolderNotFound, new ResponseCodeInfo("Unable to find the specified managed folder in the Active Directory.", "The folder name specified in the request does not map to a managedfolder definition in the Active Directory. You can create instances of managedfolders only for folders defined in the Active Directory. Check thename and try again.Appendix A Response CodesAppendix A Response CodesErrorManagedFoldersRootFailureMessage Failed to create or bind to the folder: Managed FoldersApplicable methods CreateManagedFolderManaged folders typically exist within the root managed folders folder.The root must be properly created and functional in order to deal withmanaged folders through Exchange Web Services. Typically, this configurationhappens transparently when you start dealing with managed folders.This response code indicates that the managed folders root was deletedfrom the Mailbox or that there is already a folder in the same parent folderwith the name of the managed folder root. This response code also occursif the attempt to create the root managed folder fails."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorManagedFolderAlreadyExists, new ResponseCodeInfo("The specified Managed Folder already exists in the mailbox.", "The managed folder that you are trying to create already exists in yourMailbox."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorCreateManagedFolderPartialCompletion, new ResponseCodeInfo("Failed to create one or more of the specified managed folders.", "Indicates that one ore more of the managed folders passed toCreateManagedFolder failed to be created. The only way to determinewhich ones failed is to search for the folders and see which ones do notexist."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorManagedFoldersRootFailure, new ResponseCodeInfo("Failed to create or bind to the folder: Managed Folders", "Managed folders typically exist within the root managed folders folder.The root must be properly created and functional in order to deal withmanaged folders through Exchange Web Services. Typically, this configurationhappens transparently when you start dealing with managed folders.This response code indicates that the managed folders root was deletedfrom the Mailbox or that there is already a folder in the same parent folderwith the name of the managed folder root. This response code also occursif the attempt to create the root managed folder fails."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorEmailAddressMismatch, new ResponseCodeInfo("The email address for the distinguished folder Id does not match the mailboxyou are operating on.", "The Mailbox subelement of DistinguishedFolderId pointed to a differentMailbox than the one you are currently operating on. For example, youcannot create a search folder that exists in one Mailbox but considers distinguishedfolders from another Mailbox in its search criteria."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorEventNotFound, new ResponseCodeInfo("The watermark used for creating this subscription was not found.", "Indicates that the subscription that was created with a particular watermarkis no longer valid.Appendix A Response CodesAppendix A Response CodesErrorExpiredSubscriptionMessage Subscription information is not available. Subscription is expired.Applicable methods GetEventsIndicates that the subscription referenced by GetEvents has expired."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorExpiredSubscription, new ResponseCodeInfo("Subscription information is not available. Subscription is expired.", "Indicates that the subscription referenced by GetEvents has expired."));
            //this.ResponseCodeDictionary.Add(ServiceError.ErrorExternalFacingCAS, new ResponseCodeInfo("", ""));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorFolderCorrupt, new ResponseCodeInfo("The folder is corrupt.", "The folder is corrupt and cannot be saved. This means that you set somestrange and invalid property on the folder, or possibly that the folderwas already in some strange state before you tried to set values on it(UpdateFolder). In any case, this is not a common error."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorFolderNotFound, new ResponseCodeInfo("The specified folder could not be found in the store.", "Indicates that the folder id passed in does not correspond to a valid folder,or in delegate access cases that the delegate does not have permissions toaccess the folder."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorFolderPropertRequestFailed, new ResponseCodeInfo("", ""));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorFolderSave, new ResponseCodeInfo("The folder save operation did not succeed.", "The folder could not be created or saved due to invalid state.Appendix A Response CodesAppendix A Response CodesErrorFolderSaveFailedMessage The save operation failed or partially succeeded.Applicable methods CreateFolder, UpdateFolderThe folder could not be created or saved due to invalid state."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorFolderSaveFailed, new ResponseCodeInfo("The save operation failed or partially succeeded.", "The folder could not be created or saved due to invalid state."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorFolderSavePropertyError, new ResponseCodeInfo("The folder save operation failed due to invalid property values.", "The folder could not be created or updated due to invalid property values.The properties which caused the problem are listed in the MessageXmlelement.."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorFolderExists, new ResponseCodeInfo("A folder with the specified name already exists.", "A folder with that name already exists."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorImpersonateUserDenied, new ResponseCodeInfo("The account does not have permission to impersonate the requested user.", "This response code is always returned within a SOAP fault. It indicates thatthe calling account does not have the ms-Exch-EPI-May-Impersonate righton either the user/contact they are try to impersonate or the Mailbox databasecontaining the user Mailbox.Appendix A Response CodesAppendix A Response CodesErrorImpersonationDeniedMessage The server to which the application is connected cannot impersonate therequested user due to insufficient permission.Applicable methods All methods except GetUserAvailability, GetUserOofSettings andSetUserOofSettingsThis response code is always returned within a SOAP fault. It indicates thatthe calling account does not have the ms-Exch-EPI-Impersonation right onthe CAS it is calling."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorImpersonationDenied, new ResponseCodeInfo("The server to which the application is connected cannot impersonate therequested user due to insufficient permission.", "This response code is always returned within a SOAP fault. It indicates thatthe calling account does not have the ms-Exch-EPI-Impersonation right onthe CAS it is calling."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorImpersonationFailed, new ResponseCodeInfo("Impersonation failed.", "There was an unexpected error trying to perform Server to Server authentication.This typically indicates that the service account running theExchange Web Services application pool is misconfigured, that ExchangeWeb Services cannot talk to the Active Directory, or that a trust betweenActive Directory forests is not properly configured."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorIncorrectSchemaVersion, new ResponseCodeInfo("", ""));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorIncorrectUpdatePropertyCount, new ResponseCodeInfo("An object within a change description must contain one and only oneproperty to modify.", "Each change description within an UpdateItem or UpdateFolder call mustlist one and only one property to update."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorInsufficientResources, new ResponseCodeInfo("Resources are unavailable. Try again later.", "Indicates that the Mailbox server is overloaded You should try your requestagain later.Appendix A Response CodesAppendix A Response CodesErrorInternalServerErrorMessage An internal server error occurred. The operation failed.Applicable methods All methodsThis response code means that the Exchange Web Services team membersdidn't anticipate all possible scenarios, and therefore Exchange WebServices encountered a condition that it couldn't recover from."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorInternalServerError, new ResponseCodeInfo("An internal server error occurred. The operation failed.", "This response code means that the Exchange Web Services team membersdidn't anticipate all possible scenarios, and therefore Exchange WebServices encountered a condition that it couldn't recover from."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorInternalServerTransientError, new ResponseCodeInfo("An internal server error occurred. Try again later.", "This response code is an interesting one. It essentially means that theExchange Web Services team members didn't anticipate all possible scenarios,but the nature of the unexpected condition is such that it is likelytemporary and so you should try again later."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorInvalidAttachmentId, new ResponseCodeInfo("The specified attachment Id is invalid.", "Indicates that the attachment was not found within the attachments collectionon the item in question. You might encounter this if you havean attachment id, the attachment is deleted, and then you try to callGetAttachment on the old attachment id.Appendix A Response CodesAppendix A Response CodesErrorInvalidAttachmentSubfilterMessage Attachment subfilters must have a single TextFilter therein.*Applicable methods GetFolder (on a search folder)Exchange Web Services supports only simple contains filters against theattachment table. If you try to retrieve the search parameters on an existingsearch folder that has a more complex attachment table restriction(called a subfilter), then Exchange Web Services has no way of renderingthe XML for that filter, and it returns this response code. Note that you canstill call GetFolder on this folder, just don't request the SearchParametersproperty.*David Sterling claims responsibility for the use of therein in this error message. He was hoping to get more abnormal words in Exchange WebServices response codes such as 'The Id element must have a valid value betwixt the starting and ending tags,' but he never got around to it."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorInvalidAttachmentSubfilter, new ResponseCodeInfo("Attachment subfilters must have a single TextFilter therein.*", "Exchange Web Services supports only simple contains filters against theattachment table. If you try to retrieve the search parameters on an existingsearch folder that has a more complex attachment table restriction(called a subfilter), then Exchange Web Services has no way of renderingthe XML for that filter, and it returns this response code. Note that you canstill call GetFolder on this folder, just don't request the SearchParametersproperty.*David Sterling claims responsibility for the use of therein in this error message. He was hoping to get more abnormal words in Exchange WebServices response codes such as 'The Id element must have a valid value betwixt the starting and ending tags,' but he never got around to it."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorInvalidAttachmentSubfilterTextFilter, new ResponseCodeInfo("Attachment subfilters must have a single TextFilter on the display nameonly.", "Exchange Web Services supports only simple contains filters against theattachment table. If you try to retrieve the search parameters on an existingsearch folder that has a more complex attachment table restriction,then Exchange Web Services has no way of rendering the XML for thatfilter. This specific case means that the attachment subfilter is a contains(text) filter, but the subfilter is not referring to the attachment displayname.Note that you can still call GetFolder on this search folder, just don't requestthe SearchParameters property."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorInvalidChangeKey, new ResponseCodeInfo("The change key is invalid.", "Indicates that the passed in change key was invalid. Note that many methodsdo not require a change key to be passed. However, if you do provideone, it must be a valid, though not necessarily up-to-date, change key.Appendix A Response CodesAppendix A Response CodesErrorInvalidClientSecurityContextMessage The supplied client security context is invalid.Applicable methods GetUserAvailabilityIndicates that there was an internal error related to trying to resolve thecaller's identity. This is not a common error."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorInvalidCompleteDate, new ResponseCodeInfo("CompleteDate cannot be set to a date in the future.", "Occurs when you try to set the CompleteDate of a task to a date in thepast. When converted to the local time of the CAS, the CompleteDate cannotbe set to a value less than the local time on the CAS."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorInvalidDelegatePermission, new ResponseCodeInfo("", ""));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorInvalidDelegateUserId, new ResponseCodeInfo("", ""));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorInvalidExcludesRestriction, new ResponseCodeInfo("Second operand in Excludes expression must be unit compatible.", "The bitmask passed into the Excludes restriction was unparsable.Appendix A Response CodesAppendix A Response CodesErrorInvalidExpressionTypeForSubFilterMessage FieldURI can only be used in Contains expressions.Applicable methods Finditem, FindFolder, CreateFolder (search folder), UpdateFolder (searchfolder)You should never encounter this response code."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorInvalidExpressionTypeForSubFilter, new ResponseCodeInfo("FieldURI can only be used in Contains expressions.", "You should never encounter this response code."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorInvalidExtendedProperty, new ResponseCodeInfo("The extended property attribute combination is invalid.", "The combination of extended property values that were specified is invalidor results in a bad extended property URI."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorInvalidExtendedPropertyValue, new ResponseCodeInfo("The extended property value is inconsistent with its type.", "The value offered for the extended property is inconsistent with thetype specified in the associated extended field URI. For example, if thePropertyType on the extended field URI is set to String, but you set thevalue of the extended property as an array of integers, you will encounterthis error."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorInvalidFolderId, new ResponseCodeInfo("Folder Id is invalid.", "You should never encounter this response code"));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorInvalidFolderTypeForOperation, new ResponseCodeInfo("", ""));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorInvalidFractionalPagingParameters, new ResponseCodeInfo("Invalid fractional paging offset values.", "This response code will occur if:Numerator > denominatorNumerator < 0Denominator <= 0Appendix A Response CodesAppendix A Response CodesErrorInvalidFreeBusyViewTypeMessage The free/busy view type specified in the request is invalid.Applicable methods GetUserAvailabilityReturned if you call GetUserAvailability with a FreeBusyViewType of None"));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorInvalidId, new ResponseCodeInfo("The Id is invalid.", "Indicates that the the Id and/or change key is malformed"));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorInvalidIdEmpty, new ResponseCodeInfo("Id must be non-empty.", "Occurs if you pass in an empty id (Id='')"));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorInvalidIdMalformed, new ResponseCodeInfo("Id is malformed.", "Indicates that the Id is malformed."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorInvalidIdMalformedEwsLegacyIdFormat, new ResponseCodeInfo("", ""));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorInvalidIdMonikerTooLong, new ResponseCodeInfo("Moniker exceeded allowable length.", "Here is an example of over-engineering. Once again, this indicates that thestructure of the id is malformed The moniker referred to in the name ofthis response code is contained within the id and indicates which Mailboxthe id belongs to. Exchange Web Services checks the length of this monikerand fails it if the byte count is more than expected.The check is good, but there is no reason to have a separate responsecode for this condition."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorInvalidIdNotAnItemAttachmentId, new ResponseCodeInfo("The Id does not represent an item attachment.", "The AttachmentId specified does not refer to an item attachment.Appendix A Response CodesAppendix A Response CodesErrorInvalidIdReturnedByResolveNamesMessage ResolveNames returned an invalid Id.Applicable methods ResolveNamesYou should never encounter this response code. If you do, it indicates thata contact in your Mailbox is so corrupt that Exchange Web Services reallycan't tell the difference between it and a waffle maker."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorInvalidIdStoreObjectIdTooLong, new ResponseCodeInfo("Id exceeded allowable length.", "Treat this like ErrorInvalidIdMalformed. Indicates that the id was malformed"));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorInvalidIdReturnedByResolveNames, new ResponseCodeInfo("ResolveNames returned an invalid Id.", "You should never encounter this response code. If you do, it indicates thata contact in your Mailbox is so corrupt that Exchange Web Services reallycan't tell the difference between it and a waffle maker."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorInvalidIdTooManyAttachmentLevels, new ResponseCodeInfo("Too many attachment levels.", "Exchange Web Services allows for attachment hierarchies to be a maximumof 255 levels deep. If the attachment hierarchy on an item exceeds255 levels, you will get this response code."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorInvalidIdXml, new ResponseCodeInfo("The Id Xml is invalid.", "You will never encounter this response code."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorInvalidIndexedPagingParameters, new ResponseCodeInfo("The specified indexed paging values are invalid.", "Indicates that the offset was < 0."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorInvalidInternetHeaderChildNodes, new ResponseCodeInfo("Only one child node is allowed when setting an Internet Header.", "You will never encounter this response code. At one point in the ExchangeWeb Services development cycle, you could update the Internet messageheaders via UpdateItem. Because that is no longer the case, this responsecode is unused.Appendix A Response CodesAppendix A Response CodesErrorInvalidItemForOperationCreateItemAttachmentMessage Item type is invalid for CreateItemAttachment operation.Applicable methods CreateItemIndicates that you tried to create an item attachment by using an unsupporteditem type. Supported item types for item attachments are Item,Message, CalendarItem, Contact, and Task. For instance, if you try to createa MeetingMessage attachment, you encounter this response code.In fact, the schema indicates that MeetingMessage, MeetingRequest,MeetingResponse, and MeetingCancellation are all permissible. Don't believeit."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorInvalidItemForOperationCreateItemAttachment, new ResponseCodeInfo("Item type is invalid for CreateItemAttachment operation.", "Indicates that you tried to create an item attachment by using an unsupporteditem type. Supported item types for item attachments are Item,Message, CalendarItem, Contact, and Task. For instance, if you try to createa MeetingMessage attachment, you encounter this response code.In fact, the schema indicates that MeetingMessage, MeetingRequest,MeetingResponse, and MeetingCancellation are all permissible. Don't believeit."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorInvalidItemForOperationCreateItem, new ResponseCodeInfo("Item type is invalid for CreateItemAttachment operation.", "Indicates that you tried to create an item attachment by using an unsupporteditem type. Supported item types for item attachments are Item,Message, CalendarItem, Contact, and Task. For instance, if you try to createa MeetingMessage attachment, you encounter this response code.In fact, the schema indicates that MeetingMessage, MeetingRequest,MeetingResponse, and MeetingCancellation are all permissible. Don't believeit."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorInvalidItemForOperationAcceptItem, new ResponseCodeInfo("Item type is invalid for AcceptItem action.", "This response code is returned if:You created an AcceptItem response object and referenced an item typeother than a meeting request or a calendar item.You tried to accept a calendar item occurrence that is in the deleted itemsfolder."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorInvalidItemForOperationDeclineItem, new ResponseCodeInfo("Item type is invalid for DeclineItem operation.", "This response code is returned if:You created a DeclineItem response object referencing an item with a typeother than a meeting request or a calendar item.You tried to decline a calendar item occurrence that is in the deleted itemsfolder."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorInvalidItemForOperationCancelItem, new ResponseCodeInfo("Item type is invalid for CancelCalendarItem action.", "You created a CancelItem response object and referenced an item typeother than a calendar item.Appendix A Response CodesAppendix A Response CodesErrorInvalidItemForOperationDeclineItemMessage Item type is invalid for DeclineItem operation.Applicable methods CreateItem (with a DeclineItem response object)This response code is returned if:You created a DeclineItem response object referencing an item with a typeother than a meeting request or a calendar item.You tried to decline a calendar item occurrence that is in the deleted itemsfolder."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorInvalidItemForOperationExpandDL, new ResponseCodeInfo("ExpandDL operation does not support this item type.", "The ItemId passed to ExpandDL does not represent a distribution list. Forexample, you cannot expand a Message."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorInvalidItemForOperationRemoveItem, new ResponseCodeInfo("Item type is invalid for RemoveItem operation.", "You created a RemoveItem response object reference an item with a typeother than a meeting cancellation."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorInvalidItemForOperationSendItem, new ResponseCodeInfo("Item type is invalid for SendItem operation.", "You tried to send an item with a type that does not derive fromMessageItem. Only items whose ItemClass begins with 'IPM.Note' aresendable"));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorInvalidItemForOperationTentative, new ResponseCodeInfo("Item type is invalid for TentativelyAcceptItem action.", "This response code is returned if:You created a TentativelyAcceptItem response object referencing an itemwhose type is not a meeting request or a calendar item.You tried to tentatively accept a calendar item occurrence that is in thedeleted items folder.Appendix A Response CodesAppendix A Response CodesErrorInvalidManagedFolderPropertyMessage The Managed Folder property is corrupt or otherwise invalid.Applicable methods GetFolder (requesting managed folder information)Indicates that the structure of the managed folder is corrupt and cannotbe rendered."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorInvalidOofParameter, new ResponseCodeInfo("N/A", "You will never encounter this response code."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorInvalidNameForNameResolution, new ResponseCodeInfo("The specified vakue [sic] is not a valid name for name resolution.", "Indicates that the name passed into ResolveNames was invalid. For instance,a zero length string, a single space, a comma, and a dash are allinvalid names. Vakue? Yes, that is part of the message text, although itshould obviously be 'value.'Appendix A Response CodesAppendix A Response CodesErrorInvalidNetworkServiceContextMessage The acquired network service context has invalid identity.Applicable methods GetUserAvailabilityIndicates that there is a problem with the NetworkService account on theCAS. This response code is quite rare and has been seen only in the wildby the most vigilant of hunters."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorInvalidOperation, new ResponseCodeInfo("", ""));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorInvalidPagingMaxRows, new ResponseCodeInfo("MaxEntriesReturned must be greater than zero.", "Indicates that you specified a MaxRows value that is <= 0."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorInvalidParentFolder, new ResponseCodeInfo("Cannot create a subfolder within a SearchFolder.", "You tried to create a folder within a search folder."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorInvalidPercentCompleteValue, new ResponseCodeInfo("PercentComplete must be an integer between 0 and 100.", "You tried to set the percentage complete property to an invalid value(must be between 0 and 100 inclusive)."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorInvalidPhoneCallId, new ResponseCodeInfo("", ""));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorInvalidPhoneNumber, new ResponseCodeInfo("", ""));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorInvalidPropertyAppend, new ResponseCodeInfo("The append action is not supported for this property.", "The property that you are trying to append to does not support appending.Currently, the only properties that support appending are:-Recipient collections (ToRecipients, CcRecipients, BccRecipients).-Attendee collections (RequiredAttendees, OptionalAttendees, Resources)-Body.-ReplyTo.Appendix A Response CodesAppendix A Response CodesErrorInvalidPropertyDeleteMessage The delete action is not supported for this property.Applicable methods UpdateItem (with a DeleteItemFieldType change description), UpdateFolder(with a DeleteFolderFieldType change description)The property that you are trying to delete does not support deleting. Anexample of this is trying to delete the ItemId of an item."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorInvalidPropertyDelete, new ResponseCodeInfo("The delete action is not supported for this property.", "The property that you are trying to delete does not support deleting. Anexample of this is trying to delete the ItemId of an item."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorInvalidPropertyForExists, new ResponseCodeInfo("Property cannot be used in Exists expression. Use IsEqualTo instead.", "You cannot pass in a flags property to an Exists filter. The flags propertiesare IsDraft, IsSubmitted, IsUnmodified, IsResend, IsFromMe, and IsRead. UseIsEqualTo instead.The reason that flag don't make sense in an Exists filter is that each ofthese flags is actually a bit within a single property. So, calling Exists() onone of these flags is like asking if a given bit exists within a value, which isdifferent than asking if that value exists or if the bit is set. Likely you reallymean to see if the bit is set, and you should use the IsEqualTo filter expressioninstead.."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorInvalidPropertyRequest, new ResponseCodeInfo("Property is not valid for this object type.", "Indicates that you requested a property in the response shape, and thatproperty is not within the schema of the item type in question. For example,requesting calendar:OptionalAttendees in the response shape ofGetItem when binding to a message would result in this error."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorInvalidPropertySet, new ResponseCodeInfo("Set action is invalid for property.", "The property you are trying to set is read-only.Appendix A Response CodesAppendix A Response CodesErrorInvalidPropertyUpdateSentMessageMessage Update operation is invalid for property of a sent message.Applicable methods UpdateItemYou cannot update a Message that has already been sent."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorInvalidPropertyForOperation, new ResponseCodeInfo("Property is not valid for this operation.", "Indicates that the property you are trying to manipulate does not supportwhatever operation your are trying to perform on it."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorInvalidPropertyUpdateSentMessage, new ResponseCodeInfo("ErrorInvalidPropertyUpdateSentUpdate operation is invalid for property of a sent message.", "You cannot update a Message that has already been sent."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorInvalidPullSubscriptionId, new ResponseCodeInfo("SubscriptionId is invalid. Subscription is not a pull subscription.", "You cannot call GetEvents or Unsubscribe on a push subscription id. Tounsubscribe from a push subscription, you must respond to a push requestwith an unsubscribe response, or simply disconnect your Web service andwait for the push notifications to time out."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorInvalidPushSubscriptionUrl, new ResponseCodeInfo("URL specified for push subscription is invalid.", "The URL provided as a callback for the push subscription has a bad format.The following conditions must be met for Exchange Web Services to acceptthe the URL:-String length > 0 and < 2083-Protocol is HTTP or HTTPS-Must be parsable by the System.Uri .NET Framework class"));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorInvalidRecipients, new ResponseCodeInfo("One or more recipients are invalid.", "You should never encounter this response code. If you do, the recipientcollection on your message or attendee collection on your calendar itemis invalid."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorInvalidRecipientSubfilter, new ResponseCodeInfo("Recipient subfilters are only supported when there are two expressionswithin a single AND filter.", "Indicates that the search folder in question has a recipient table filter thatExchange Web Services cannot represent. The response code is a littlemisleading'there is nothing invalid about the search folder restriction. Toget around this issue, call GetFolder without requesting the search parameters.Appendix A Response CodesAppendix A Response CodesErrorInvalidRecipientSubfilterComparisonMessage Recipient subfilter must have a comparison filter that tests equality to recipienttype or attendee type.Applicable methods GetFolder (SearchFolder with search parameters)Indicates that the search folder in question has a recipient table filterthat Exchange Web Services cannot represent. The error code is a littlemisleading'there is nothing invalid about the search folder restriction..To get around this, issue, call GetFolder without requesting the search parameters."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorInvalidRecipientSubfilterComparison, new ResponseCodeInfo("Recipient subfilter must have a comparison filter that tests equality to recipienttype or attendee type.", "Indicates that the search folder in question has a recipient table filterthat Exchange Web Services cannot represent. The error code is a littlemisleading'there is nothing invalid about the search folder restriction..To get around this, issue, call GetFolder without requesting the search parameters."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorInvalidRecipientSubfilterOrder, new ResponseCodeInfo("Recipient subfilters must have a text filter and a comparison filter in thatorder.", "Indicates that the search folder in question has a recipient table filter thatExchange Web Services cannot represent. The response code is a little misleading'there is nothing invalid about the search folder restriction To getaround this,issue, call GetFolder without requesting the search parameters."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorInvalidRecipientSubfilterTextFilter, new ResponseCodeInfo("Recipient subfilter must have a TextFilter on the SMTP address only.", "Can you guess our comments on this one? Indicates that the search folderin question has a recipient table filter that Exchange Web Services cannotrepresent. The error code is a little misleading'there is nothing invalidabout the search folder restriction. To get around this issue, call GetFolderwithout requesting the search parameters."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorInvalidReferenceItem, new ResponseCodeInfo("The reference item does not support the requested operation.", "You can only reply to/forward a Message, CalendarItem, or their descendants.If you are referencing a CalendarItem and you are the organizer,you can only forward the item. If you are referencing a draft message, youcannot reply to the item.For read receipt suppression, you can reference only a Message or descendant.Appendix A Response CodesAppendix A Response CodesErrorInvalidRequestMessage The request is invalid.Applicable methods All methodsIndicates that the SOAP request has a SOAP Action header, but nothing inthe SOAP body. Note that the SOAP Action header is not required becauseExchange Web Services can determine the method to call from the localname of the root element in the SOAP body. However, you must supplycontent in the SOAP body or else there is really nothing for Exchange WebServices to act on.."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorInvalidRequest, new ResponseCodeInfo("The request is invalid.", "Indicates that the SOAP request has a SOAP Action header, but nothing inthe SOAP body. Note that the SOAP Action header is not required becauseExchange Web Services can determine the method to call from the localname of the root element in the SOAP body. However, you must supplycontent in the SOAP body or else there is really nothing for Exchange WebServices to act on.."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorInvalidRestriction, new ResponseCodeInfo("The restriction is invalid.", "You will never encounter this response code."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorInvalidRoutingType, new ResponseCodeInfo("The routing type format is invalid.", "Indicates that the RoutingType element that was passed for anEmailAddressType is not a valid routing type. Typically, routing type will beset to Simple Mail Transfer Protocol (SMTP)."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorInvalidScheduledOofDuration, new ResponseCodeInfo("The scheduled Out of Office duration is not valid.", "The specified duration end time must be greater than the start time andmust occur in the future."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorInvalidSchemaVersionForMailboxVersion, new ResponseCodeInfo("", ""));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorInvalidSendItemSaveSettings, new ResponseCodeInfo("Invalid combination of SaveItemToFolder attribute and SavedItemFolderIdelement.", "The SaveItemToFolder attribute is false, but you included aSavedItemFolderId."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorInvalidSerializedAccessToken, new ResponseCodeInfo("Invalid serialized access token.", "Because you never use token serialization in your application, you shouldnever encounter this response code. The response code occurs if the tokenpassed in the SOAP header is malformed, doesn't refer to a valid accountin the Active Directory, or is missing the primary group SID."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorInvalidServerVersion, new ResponseCodeInfo("", ""));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorInvalidSid, new ResponseCodeInfo("A SID with an invalid format was encountered: {Bad SID in SDDL form}", "Indicates that one or more of the SIDs within the passed token orExchangeImpersonation element have an invalid structure."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorInvalidSIPUri, new ResponseCodeInfo("", ""));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorInvalidSubfilterType, new ResponseCodeInfo("Invalid subFilterType.", "You will never encounter this response code."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorInvalidSubfilterTypeNotAttendeeType, new ResponseCodeInfo("SubFilterType is not attendee type.", "You will never encounter this response code.Appendix A Response CodesAppendix A Response CodesErrorInvalidSubfilterTypeNotRecipientTypeMessage SubFilterType is not recipient type.Applicable methods N/AYou will never encounter this response code."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorInvalidSubfilterTypeNotRecipientType, new ResponseCodeInfo("SubFilterType is not recipient type.", "You will never encounter this response code."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorInvalidSubscription, new ResponseCodeInfo("Subscription is invalid.", "Indicates that the subscription is no longer valid. This could be due to theCAS having been rebooted or because the subscription has expired."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorInvalidSubscriptionRequest, new ResponseCodeInfo("", ""));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorInvalidSyncStateData, new ResponseCodeInfo("Synchronization state data is corrupt or otherwise invalid.", "Indicates that the sync state data is corrupt. You need to resync withoutthe sync state. Make sure that if you are persisting sync state somewhere,you are not accidentally altering the information.."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorInvalidUserOofSettings, new ResponseCodeInfo("The specified Out of Office settings are not valid.", "The user OOF settings are invalid due to a missing internal or external reply."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorInvalidUserPrincipalName, new ResponseCodeInfo("The impersonation principal name is invalid.", "Indicates that the UPN passed in the ExchangeImpersonation SOAP headerdid not map to a valid account.Appendix A Response CodesAppendix A Response CodesErrorInvalidUserSidMessage The user SID is invalid or does not map to a user in the Active Directory.Applicable methods All methods with a SID in the ExchangeImpersonation SOAP headerIndicates that the SID passed in the ExchangeImpersonation SOAP headerwas either invalid or did not map to a valid account."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorInvalidUserSid, new ResponseCodeInfo("The user SID is invalid or does not map to a user in the Active Directory.", "Indicates that the SID passed in the ExchangeImpersonation SOAP headerwas either invalid or did not map to a valid account."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorInvalidUserSidMissingUPN, new ResponseCodeInfo("N/A", "You will never encounter this response code."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorInvalidValueForProperty, new ResponseCodeInfo("The specified value is invalid for property.", "Indicates that the comparison value is invalid for the property your arecomparing against. For instance, DateTimeCreated > 'true' would causethis response code to be returned. You also encounter this response codeif you specify an enumeration property in the comparison, but the valueyou are comparing against is not a valid value for that enumeration."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorInvalidWatermark, new ResponseCodeInfo("The watermark is invalid.", "Indicates that the supplied watermark is corrupt."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorIPGatewayNotFound, new ResponseCodeInfo("", ""));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorIrresolvableConflict, new ResponseCodeInfo("The send or update operation could not be performed because thechange key passed in the request does not match the current change keyfor the item.", "Indicates that conflict resolution was unable to resolve changes for theproperties in question. This typically means that someone changed theitem in the Store, and you are dealing with a stale copy. Retrieve the updatedchange key and try again.Appendix A Response CodesAppendix A Response CodesErrorItemCorruptMessage The item is corrupt.Applicable methods GetItem with Body, CreateItem, CreateFolder, UpdateItem, UpdateFolderIndicates that the state of the object is corrupt and cannot be retrieved.When retrieving an item, typically only certain properties will be in thisstate (i.e. Body, MimeContent, ). Try omitting those properties and retryingthe operation."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorItemCorrupt, new ResponseCodeInfo("The item is corrupt.", "Indicates that the state of the object is corrupt and cannot be retrieved.When retrieving an item, typically only certain properties will be in thisstate (i.e. Body, MimeContent, ). Try omitting those properties and retryingthe operation."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorItemNotFound, new ResponseCodeInfo("The specified object was not found in the store.", "Indicates that the item in question was not found, or potentially that it reallydoes exist, and you just don't have rights to access it."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorItemPropertyRequestFailed, new ResponseCodeInfo("One or more of the properties requested for this item could not be retrieved.", "Exchange Web Services tried to retrieve a given property on an item orfolder but failed to do so. Note that this means that some value was there,but Exchange Web Services was unable to retrieve it."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorItemSave, new ResponseCodeInfo("The item save operation did not succeed.", "Attempts to save the item/folder failed."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorItemSavePropertyError, new ResponseCodeInfo("Item save operation did not succeed.", "Attempts to save the item/folder failed because of invalid property values.The response includes the offending property paths."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorMailboxConfiguration, new ResponseCodeInfo("Unable to access an account or mailbox.", "Indicates that the Mailbox information in the Active Directory is misconfigured."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorMailboxMoveInProgress, new ResponseCodeInfo("Mailbox move in progress. Try again later.", "The Mailbox in question is currently being moved. Try your request againonce the move is complete."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorMailboxStoreUnavailable, new ResponseCodeInfo("The Mailbox database is temporarily unavailable.", "The Maibox database is offline, corrupt, shutting down, or involved in aplethora of other conditions that make the Mailbox unavailable."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorMessageDispositionRequired, new ResponseCodeInfo("MessageDisposition attribute is required.", "When creating or updating an item that descends from MessageType, youmust supply the MessageDisposition attribute on the request to indicatewhat operations should be performed on the message. Note that this attributeis not required for any other type of item."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorMessageSizeExceeded, new ResponseCodeInfo("The message exceeds the maximum supported size.", "Indicates that the message you are trying to send exceeds the allowablelimits."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorMimeContentConversionFailed, new ResponseCodeInfo("MIME content conversion failed.", "For CreateItem, the MIME content was not valid iCalendar content ForGetItem, the MIME content could not be generated.Appendix A Response CodesAppendix A Response CodesErrorMimeContentInvalidMessage Invalid MIME content.Applicable methods CreateItem (with MimeContent)The MIME content to set is invalid."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorMimeContentInvalid, new ResponseCodeInfo("Invalid MIME content.", "The MIME content to set is invalid."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorMimeContentInvalidBase64String, new ResponseCodeInfo("Invalid base64 string for MIME content.", "The MIME content in the request is not a valid Base64 string."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorMissingEmailAddress, new ResponseCodeInfo("When making a request as an account that does not have a mailbox, youmust specify the mailbox primary SMTP address for any distinguishedfolder Ids.", "Indicates that you specified a distinguished folder id in the request,but the account that made the request does not have a Mailbox onthe system. In that case, you must supply a Mailbox subelement underDistinguishedFolderId."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorMissingEmailAddressForManagedFolder, new ResponseCodeInfo("When making a request with an account that does not have a mailbox,you must specify the primary SMTP address for an existing mailbox.", "This is really the same failure as ErrorMissingEmailAddress exceptthat ErrorMissingEmailAddressForManagedFolder is returned fromCreateManagedFolder.Appendix A Response CodesAppendix A Response CodesErrorMissingInformationEmailAddressMessage EmailAddress or ItemId must be included in the request.Applicable methods CreateItem, UpdateItem (when recipients or attendees are provided)Indicates that the attendee or recipient does not have the EmailAddresselement set. You must set this element when making requests. The othertwo elements within EmailAddressType are optional (name and routingtype)."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorMissingInformationEmailAddress, new ResponseCodeInfo("EmailAddress or ItemId must be included in the request.", "Indicates that the attendee or recipient does not have the EmailAddresselement set. You must set this element when making requests. The othertwo elements within EmailAddressType are optional (name and routingtype)."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorMissingInformationReferenceItemId, new ResponseCodeInfo("ReferenceItemId must be included in the request.", "When creating a response object such as ForwardItem, you must supply areference item id."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorMissingItemForCreateItemAttachment, new ResponseCodeInfo("An item must be specified when creating an item attachment.", "When creating an item attachment, you must include a child element indicatingthe item that you want to create. This response code is returned ifyou omit this element."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorMissingRecipients, new ResponseCodeInfo("A message needs to have at least one recipient.", "Indicates you tried to send an item with no recipients. Note that if you callCreateItem with a message disposition that causes the message to be sent,you get a different response code (ErrorInvalidRecipients).Appendix A Response CodesAppendix A Response CodesErrorMoreThanOneAccessModeSpecifiedMessage Only one access mode header may be specified.Applicable methods All methodsWhen using Server to Server authentication, you can specify only a singleExchangeImpersonation or SerializedSecurityContext SOAP header within arequest."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorMissingUserIdInformation, new ResponseCodeInfo("", ""));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorMoreThanOneAccessModeSpecified, new ResponseCodeInfo("Only one access mode header may be specified.", "When using Server to Server authentication, you can specify only a singleExchangeImpersonation or SerializedSecurityContext SOAP header within arequest."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorMoveCopyFailed, new ResponseCodeInfo("The move or copy operation failed.", "Indicates that the move or copy operation failed.A move occurs in CreateItem when you accept a meeting request that isin the Deleted Items folder. In addition, if you decline a meeting request,cancel a calendar item, or remove a meeting from your calendar, it getsmoved to the deleted items folder."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorMoveDistinguishedFolder, new ResponseCodeInfo("Cannot move distinguished folder.", "You cannot move a distinguished folder."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorNameResolutionMultipleResults, new ResponseCodeInfo("Multiple results were found.", "This is not actually an error. It should be categorized as a warning. Thisresponse code indicates that the ambiguous name that you specifiedmatched more than one contact or distribution list.. This is also the only'error' response code that includes response data (the matched names)."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorNameResolutionNoMailbox, new ResponseCodeInfo("User must have a mailbox for name resolution operations.", "Indicates that the effective caller does not have a Mailbox on the system.Name resolution considers both the Active Directory as well as the StoreMailbox."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorNameResolutionNoResults, new ResponseCodeInfo("No results were found.", "The ambiguous name did not match any contacts in either the ActiveDirectory or the Mailbox.Appendix A Response CodesAppendix A Response CodesErrorNoCalendarMessage The target user does not have a calendar.Applicable methods GetUserAvailabilityThere was no calendar folder for the Mailbox in question."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorNoApplicableProxyCASServersAvailable, new ResponseCodeInfo("", ""));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorNoDestinationCASDueToKerberosRequirements, new ResponseCodeInfo("", ""));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorNoDestinationCASDueToSSLRequirements, new ResponseCodeInfo("", ""));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorNoDestinationCASDueToVersionMismatch, new ResponseCodeInfo("", ""));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorNoFolderClassOverride, new ResponseCodeInfo("You cannot specify the FolderClass when creating a non-generic folder.", "You can set the FolderClass only when creating a generic folder. For typedfolders (i.e. CalendarFolder and TaskFolder, the folder class is implied.Note that if you try to set the folder class to a different folder type viaUpdateFolder, you get ErrorObjectTypeChanged'so don't even try it (weknew you were going there').Exchange Web Services should enable you to create a more specialized'but consistent'folder class when creating a strongly typed folder. To getaround this issue, use a generic folder type but set the folder class to thevalue you need. Exchange Web Services then creates the correct stronglytyped folder."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorNonExistentMailbox, new ResponseCodeInfo("The SMTP address has no mailbox associated with it.", "This response code is returned in two cases:-(CreateManagedFolder) You specified a Mailbox element in your requestbut you either omitted the EmailAddress child element or thevalue in the EmailAddress element is empty (String.Empty).-The SMTP address does not map to a valid Mailbox.Appendix A Response CodesAppendix A Response CodesErrorNonPrimarySmtpAddressMessage The primary SMTP address must be specified when referencing a mailbox.Applicable methods All methodsFor requests that take an SMTP address, the address must be the primarySMTP address representing the Mailbox. Non-primary SMTP addressesare not permitted. The response includes the correct SMTP address touse. Because Exchange Web Services returns the primary SMTP address, itmakes you wonder why Exchange Web Services didn't just use the proxyaddress you passed in' Note that this requirement may be removed in afuture release."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorNonPrimarySmtpAddress, new ResponseCodeInfo("The primary SMTP address must be specified when referencing a mailbox.", "For requests that take an SMTP address, the address must be the primarySMTP address representing the Mailbox. Non-primary SMTP addressesare not permitted. The response includes the correct SMTP address touse. Because Exchange Web Services returns the primary SMTP address, itmakes you wonder why Exchange Web Services didn't just use the proxyaddress you passed in' Note that this requirement may be removed in afuture release."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorNoPropertyTagForCustomProperties, new ResponseCodeInfo("Custom properties cannot be specified using property tags. The GUID andId/Name combination must be used instead.", "Messaging Application Programming Interface (MAPI) properties in thecustom range (0x8000 and greater) cannot be referenced by propertytags. You must use PropertySetId or DistinguishedPropertySetId along withPropertyName or PropertyId."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorNoPublicFolderReplicaAvailable, new ResponseCodeInfo("", ""));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorNoPublicFolderServerAvailable, new ResponseCodeInfo("", ""));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorNoRespondingCASInDestinationSite, new ResponseCodeInfo("", ""));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorNotEnoughMemory, new ResponseCodeInfo("There was not enough memory to complete the request.", "The operation could not complete due to insufficient memory."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorNotDelegate, new ResponseCodeInfo("", ""));
            //this.ResponseCodeDictionary.Add(ServiceError.ErrorObjectNotFound, new ResponseCodeInfo("", ""));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorObjectTypeChanged, new ResponseCodeInfo("Caller does not have access to free busy data.", "Indicates that the caller does not have free/busy viewing rights on the calendarfolder in question."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorOccurrenceCrossingBoundary, new ResponseCodeInfo("Modified occurrence is crossing or overlapping adjacent occurrence.", "Indicates that the time allotment for a given occurrence overlaps with oneof its neighbors."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorOccurrenceTimeSpanTooBig, new ResponseCodeInfo("One occurrence of the recurring calendar item overlaps with another occurrenceof the same calendar item.", "Indicates that the time allotment for a given occurrence is too long, whichcauses the occurrence to overlap with its neighbor. This response codealso occurs if the length in minutes of a given occurrence is larger thanInt32.MaxValue."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorOperationNotAllowedWithPublicFolderRoot, new ResponseCodeInfo("", ""));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorParentFolderIdRequired, new ResponseCodeInfo("You must specify the parent folder Id for this operation.", "You will never encounter this response code."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorParentFolderNotFound, new ResponseCodeInfo("The specified parent folder could not be found.", "The parent folder id that you specified does not exist."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorPasswordChangeRequired, new ResponseCodeInfo("Password change is required.", "You must change your password before you can access this Mailbox. Thisoccurs when a new account has been created, and the administrator indicatedthat the user must change the password at first logon. You cannotchange a password through Exchange Web Services. You must use a userapplicationsuch as Outlook Web Access (OWA) to change your password.Appendix A Response CodesAppendix A Response CodesErrorPasswordExpiredMessage Password has expired. Change password.Applicable methods All methodsThe password associated with the calling account has expired.. Youneed to change your password. You cannot change a password throughExchange Web Services. You must use a user application such as OutlookWeb Access to change your password."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorPasswordExpired, new ResponseCodeInfo("Password has expired. Change password.", "The password associated with the calling account has expired.. Youneed to change your password. You cannot change a password throughExchange Web Services. You must use a user application such as OutlookWeb Access to change your password."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorPhoneNumberNotDialable, new ResponseCodeInfo("", ""));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorPropertyUpdate, new ResponseCodeInfo("Property update did not succeed.", "Update failed due to invalid property values. The response message includesthe offending property paths."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorPropertyValidationFailure, new ResponseCodeInfo("At least one property failed validation.", "You will never encounter this response code."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorProxiedSubscriptionCallFailure, new ResponseCodeInfo("", ""));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorProxyGroupSidLimitExceeded, new ResponseCodeInfo("", ""));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorProxyCallFailed, new ResponseCodeInfo("", ""));
            //this.ResponseCodeDictionary.Add(ServiceError.ErrorProxyServerCannotSerializeTokens, new ResponseCodeInfo("", ""));
            //this.ResponseCodeDictionary.Add(ServiceError.ErrorProxyServerIsNotInExchangeServersGroup, new ResponseCodeInfo("", ""));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorProxyServiceDiscoveryFailed, new ResponseCodeInfo("", ""));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorProxyTokenExpired, new ResponseCodeInfo("", ""));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorQueryFilterTooLong, new ResponseCodeInfo("The search folder has a restriction that is too long to return.", "Restrictions can contain a maximum of 255 filter expressions. If you try tobind to an existing search folder that exceeds this limit, you encounter thisresponse code."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorQuotaExceeded, new ResponseCodeInfo("Mailbox has exceeded maximum mailbox size.", "The Mailbox quota has been exceeded."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorReadEventsFailed, new ResponseCodeInfo("Unable to retrieve events for this subscription. The subscription must berecreated.", "The process for reading events was aborted due to an internal failure. Youshould recreate the subscription based on a last known watermark.Appendix A Response CodesAppendix A Response CodesErrorReadReceiptNotPendingMessage Unable to suppress read receipt. Read receipts are not pending.Applicable methods CreateItem (SuppressReadReceipt)You cannot suppress a read receipt if the message sender did not requesta read receipt on the message."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorReadReceiptNotPending, new ResponseCodeInfo("Unable to suppress read receipt. Read receipts are not pending.", "You cannot suppress a read receipt if the message sender did not requesta read receipt on the message."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorRecurrenceEndDateTooBig, new ResponseCodeInfo("Recurrence end date can not exceed Sep 1, 4500 00:00:00.", "The end date for the recurrence was out of range (it is limited toSeptember 1, 4500)."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorRecurrenceHasNoOccurrence, new ResponseCodeInfo("Recurrence has no occurrences in the specified range.", "The recurrence has no occurrence instances in the specified range."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorRequiredPropertyMissing, new ResponseCodeInfo("Required property is missing.", "Indicates that one or more of the required properties is missing during aCreateAttachment call. The response XML indicates which property pathwas not set.Appendix A Response CodesAppendix A Response CodesErrorResponseSchemaValidationMessage The response failed schema validation.Applicable methods N/AYou will never encounter this response code. Just as a piece of trivia, theExchange Web Services design team used this response code for debugbuilds to ensure that their responses were schema compliant. If ExchangeWeb Services expects you to send schema-compliant XML, then the leastExchange Web Services can do is be compliant in return."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorResolveNamesInvalidFolderType, new ResponseCodeInfo("", ""));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorResolveNamesOnlyOneContactsFolderAllowed, new ResponseCodeInfo("", ""));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorRemoveDelegatesFailed, new ResponseCodeInfo("", ""));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorResponseSchemaValidation, new ResponseCodeInfo("The response failed schema validation.", "You will never encounter this response code. Just as a piece of trivia, theExchange Web Services design team used this response code for debugbuilds to ensure that their responses were schema compliant. If ExchangeWeb Services expects you to send schema-compliant XML, then the leastExchange Web Services can do is be compliant in return."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorRestrictionTooLong, new ResponseCodeInfo("Restriction contained too many elements.", "A restriction can have a maximum of 255 filter elements."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorRestrictionTooComplex, new ResponseCodeInfo("The restriction or sort order is too complex for this operation.", "Exchange Web Services cannot evaluate the restriction you supplied. Therestriction might appear simple, but Exchange Web Services does notagree with you."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorInvalidExchangeImpersonationHeaderData, new ResponseCodeInfo("An ExchangeImpersonation SOAP header must contain a user principalname, user SID, or primary SMTP address.", "An ExchangeImpersonation header was passed in but it did not contain asecurity identifier (SID), user principal name (UPN) or primary smtp address.You must supply one of these identifiers and of course, they cannotbe empty strings. Note that this response code is always returned within aSOAP fault."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorSavedItemFolderNotFound, new ResponseCodeInfo("The folder in which items were to be saved could not be found.", "Indicates that the folder you want to save the item to does not exist.Appendix A Response CodesAppendix A Response CodesErrorSchemaValidationMessage The request failed schema validation.Applicable methods All methodsExchange Web Services validates all incoming requests against the schemafiles (types.xsd, messages.xsd). Any instance documents that are not compliantare rejected, and this response code is returned. Note that this responsecode is always returned within a SOAP fault."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorSchemaValidation, new ResponseCodeInfo("The request failed schema validation.", "Exchange Web Services validates all incoming requests against the schemafiles (types.xsd, messages.xsd). Any instance documents that are not compliantare rejected, and this response code is returned. Note that this responsecode is always returned within a SOAP fault."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorSearchFolderNotInitialized, new ResponseCodeInfo("The search folder is not initialized.", "Indicates that the search folder has been created, but the search criteriawas never set on the folder. This condition occurs only when youaccess corrupt search folders that were created with another applicationprogramming interface (API) or client. Exchange Web Servicesdoes not enable you to create search folders with this condition To fix asearch folder that has not been initialized, call UpdateFolder and set theSearchParameters to include the restriction that should be on the folder."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorSendAsDenied, new ResponseCodeInfo("The user account which was used to submit this request does not have theright to send mail on behalf of the specified sending account.", "The caller does not have Send As rights for the account in question."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorSendMeetingCancellationsRequired, new ResponseCodeInfo("SendMeetingCancellations attribute is required for Calendar items.", "When you are the organizer and are deleting a calendar item, you mustset the SendMeetingCancellations attribute on the DeleteItem requestto indicate whether meeting cancellations will be sent to the meetingattendees. If you are using the proxy classes don't forget to set theSendMeetingCancellationsSpecified property to true.Appendix A Response CodesAppendix A Response CodesErrorSendMeetingInvitationsOrCancellationsRequiredMessage SendMeetingInvitationsOrCancellations attribute is required for Calendaritems.Applicable methods UpdateItem (calendar item)When you are the organizer and are updating a calendar item, you mustset the SendMeetingInvitationsOrCancellations attribute on the UpdateItemrequest. If you are using the proxy classes don't forget to set theSendMeetingInvitationsOrCancellationsSpecified attribute to true."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorSendMeetingInvitationsOrCancellationsRequired, new ResponseCodeInfo("SendMeetingInvitationsOrCancellations attribute is required for Calendaritems.", "When you are the organizer and are updating a calendar item, you mustset the SendMeetingInvitationsOrCancellations attribute on the UpdateItemrequest. If you are using the proxy classes don't forget to set theSendMeetingInvitationsOrCancellationsSpecified attribute to true."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorSendMeetingInvitationsRequired, new ResponseCodeInfo("SendMeetingInvitations attribute is required for calendar items.", "When creating a calendar item, you must set the SendMeetingInvitiationsattribute on the CreateItem request. If you are using the proxy classesdon't forget to set the SendMeetingInvitationsSpecified attribute to true."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorSentMeetingRequestUpdate, new ResponseCodeInfo("The meeting request has already been sent and may not be updated.", "After the organizer sends a meeting request, that request cannot be updated.If the organizer wants to modify the meeting, you need to modifythe calendar item, not the meeting request."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorSentTaskRequestUpdate, new ResponseCodeInfo("The task request has already been sent and may not be updated.", "After the task initiator sends a task request, that request cannot be updated.However, you should not encounter this response code becauseExchange Web Services does not support task assignment at this point."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorServerBusy, new ResponseCodeInfo("The server cannot service this request right now. Try again later.", "The server is busy, potentially due to virus scan operations. It is unlikelythat you will encounter this response code.Appendix A Response CodesAppendix A Response CodesErrorServiceDiscoveryFailedMessage Various messages depending on error conditionApplicable methods GetUserAvailabilityExchange Web Services tried to proxy a user availability request to theappropriate Active Directory forest for the recipient in question, but itcould not determine where to send the request due to a service discoveryfailure."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorStaleObject, new ResponseCodeInfo("The current ChangeKey is required for this operation.", "You must supply an up-to-date change key when calling the applicablemethods. You either did not supply a change key, or the change key yousupplied is stale. Call GetItem to retrieve an updated change key and thentry your operation again."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorSubmissionQuotaExceeded, new ResponseCodeInfo("", ""));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorSubscriptionAccessDenied, new ResponseCodeInfo("Access is denied. Only the subscription owner may access the subscription.", "You tried to access a subscription by using an account that did not createthat subscription. Each subscription is tied to its creator. It does not matterwhich rights one account has on the Mailbox in question. Jane's subscriptionscan only be accessed by Jane."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorSubscriptionDelegateAccessNotSupported, new ResponseCodeInfo("Subscriptions are not supported for delegate user access.", "You can cannot create a subscription if you are not the owner or do nothave owner access to the Mailbox in question."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorSubscriptionNotFound, new ResponseCodeInfo("The specified subscription was not found.", "The specified subscription does not exist which could mean that the subscriptionexpired, the Exchange Web Services process was restarted, or youpassed in an invalid subscription. If you encounter this response code, recreatethe subscription by using the last watermark that you have.Appendix A Response CodesAppendix A Response CodesErrorSyncFolderNotFoundMessage The folder to be synchronized could not be found.Applicable methods SyncFolderItemsIndicates that the folder id you specified in your SyncFolderItems requestdoes not exist."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorSyncFolderNotFound, new ResponseCodeInfo("The folder to be synchronized could not be found.", "Indicates that the folder id you specified in your SyncFolderItems requestdoes not exist."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorToFolderNotFound, new ResponseCodeInfo("The specified target folder could not be found.", "The specified destination folder does not exist"));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorTokenSerializationDenied, new ResponseCodeInfo("The requesting account does not have permission to serialize tokens.", "The calling account does not have the ms-Exch-EPI-TokenSerializationright on the CAS that is being called. Of course, because you are not usingtoken serialization in your application, you should never encounter thisresponse code. Right?"));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorUpdateDelegatesFailed, new ResponseCodeInfo("", ""));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorUpdatePropertyMismatch, new ResponseCodeInfo("Property for update does not match property in object.", "The single property path listed in a change description must match thesingle property that is being set within the actual Item/Folder element."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorUnableToGetUserOofSettings, new ResponseCodeInfo("N/A", "You will never encounter this response code.Appendix A Response CodesAppendix A Response CodesErrorUnsupportedCultureMessage The specified item culture is not supported on this server.Applicable methods CreateItem, UpdateItemYou tried to set the Culture property to a value that is not parsable by theSystem.Globalization.CultureInfo class."));
            //this.ResponseCodeDictionary.Add(ServiceError.ErrorUnableToSetUserOofSettings, new ResponseCodeInfo("", ""));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorUnifiedMessagingDialPlanNotFound, new ResponseCodeInfo("", ""));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorUnifiedMessagingRequestFailed, new ResponseCodeInfo("", ""));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorUnifiedMessagingServerNotFound, new ResponseCodeInfo("", ""));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorUnsupportedSubFilter, new ResponseCodeInfo("Unsupported subfilter type.", "You should never encounter this response code."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorUnsupportedCulture, new ResponseCodeInfo("The specified item culture is not supported on this server.", "You tried to set the Culture property to a value that is not parsable by theSystem.Globalization.CultureInfo class."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorUnsupportedMapiPropertyType, new ResponseCodeInfo("The MAPI property type is not supported.", "MAPI property types Error, Null, Object and ObjectArray are unsupported."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorUnsupportedMimeConversion, new ResponseCodeInfo("MIME conversion is not supported for this item type.", "You can retrieve or set MIME content only for a post, message, or calendaritem."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorUnsupportedPathForQuery, new ResponseCodeInfo("The property can not be used with this type of restriction.", "Indicates that the property path cannot be used within a restriction."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorUnsupportedPathForSortGroup, new ResponseCodeInfo("The property can not be used for sorting or grouping results.", "Indicates that the property path cannot be use for sorting or groupingoperations."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorUnsupportedPropertyDefinition, new ResponseCodeInfo("PropertyDefinition is not supported in searches.", "You should never encounter this response code.Appendix A Response CodesAppendix A Response CodesErrorUnsupportedQueryFilterMessage QueryFilter type is not supported.Applicable methods GetFolder (search folder)Exchange Web Services cannot render the existing search folder restriction.This response code does not mean that anything is wrong with thesearch folder restriction. You can still call FindItem on the search folder toretrieve the items in the search folder; you just can't get the actual restrictionclause."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorUnsupportedQueryFilter, new ResponseCodeInfo("QueryFilter type is not supported.", "Exchange Web Services cannot render the existing search folder restriction.This response code does not mean that anything is wrong with thesearch folder restriction. You can still call FindItem on the search folder toretrieve the items in the search folder; you just can't get the actual restrictionclause."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorUnsupportedRecurrence, new ResponseCodeInfo("The specified recurrence is not supported.", "You supplied a recurrence pattern that is not supported for tasks."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorUnsupportedTypeForConversion, new ResponseCodeInfo("Unsupported type for restriction conversion.", "You should never encounter this response code. It indicates that ExchangeWeb Services found a property type in the Store that it cannot generateXML for."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorUserNotUnifiedMessagingEnabled, new ResponseCodeInfo("", ""));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorVirusDetected, new ResponseCodeInfo("Virus detected in the message.", "The Exchange Store detected a virus in the message you are trying to dealwith.Appendix A Response CodesAppendix A Response CodesErrorVirusMessageDeletedMessage The item has been deleted as a result of a virus scan.Applicable methods All methodsThe Exchange Store detected a virus in the message and deleted it."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorVirusMessageDeleted, new ResponseCodeInfo("The item has been deleted as a result of a virus scan.", "The Exchange Store detected a virus in the message and deleted it."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorVoiceMailNotImplemented, new ResponseCodeInfo("The voicemail distinguished folder is not implemented.", "You will never encounter this response code. This was left over from thedevelopment cycle before the Exchange Web Services team had implementedvoice mail folder support. Yes, there was a time when all of thiswas not implemented."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorRequestStreamTooBig, new ResponseCodeInfo("The incoming request size is too large. The allowed size = {allowed numberof bytes} bytes; the actual size = {actual number of types} bytes.", "During GetUserAvailability processing, the request was deemed largerthan it should be. You should not encounter this response code."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorMailboxDataArrayEmpty, new ResponseCodeInfo("The MailboxData array is empty.", "Indicates that the MailboxData array in the request is empty. You mustsupply at least one Mailbox identifier."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorMailboxDataArrayTooBig, new ResponseCodeInfo("There are too many target users in the EmailAddress array. The allowedsize = {allowed size}; the actual size = {actual size}.", "You can supply a maximum of 100 entries in the MailboxData array."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorTimeIntervalTooBig, new ResponseCodeInfo("The requested time duration specified for {property name} is too long. Theallowed limit = {day count limit} days; the actual limit = {actual count ofdays} days.", "The time window specified is larger than the allowable limit (42 by default)."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorInvalidMergedFreeBusyInterval, new ResponseCodeInfo("The specified merged free/busy interval is not valid. Specify an intervalthat is less than the free/busy time window and between {lower minuterange} and {upper minute range} minutes.", "Indicates that the supplied merged free/busy internal value is invalid.Default minimum is 5 minutes. Default maximum is 1440 minutes."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorResultSetTooBig, new ResponseCodeInfo("The result set contains too many calendar entries. The allowed size = {allowedcount}; the actual size = {actual count}.", "The number of calendar entries for a given recipient exceeds the allowablelimit (1000). Reduce the window and try again."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorInvalidClientSecurityContext, new ResponseCodeInfo("The supplied client security context is invalid.", "Indicates that there was an internal error related to trying to resolve thecaller's identity. This is not a common error."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorMailboxLogonFailed, new ResponseCodeInfo("Mailbox logon failed.", "Failed to connect to the Mailbox to get the calendar view information.Appendix A Response CodesAppendix A Response CodesErrorMailboxMoveInProgressMessage Mailbox move in progress. Try again later.Applicable methods All methodsThe Mailbox in question is currently being moved. Try your request againonce the move is complete."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorMailRecipientNotFound, new ResponseCodeInfo("The mail recipient is not found in Active Directory.", "Could not map the MailboxData information to a valid Mailbox account."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorInvalidTimeInterval, new ResponseCodeInfo("The time duration specified for {property name} is invalid.", "The specified time interval is invalid (schema type Duration). The start timemust be greater than or equal to the end time."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorPublicFolderServerNotFound, new ResponseCodeInfo("The public folder server for the given legacy mailbox was not found.", "The recipient in question is located on a legacy Exchange server (prior toExchange -2007). As such, Exchange Web Services needed to contact thepublic folder server to retrieve free/busy information for that recipient.However, the organizational unit in question did not have a public folderserver associated with it."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorInvalidAccessLevel, new ResponseCodeInfo("The returned access level for the calling user identity is invalid.", "It is unlikely that you will encounter this response code. It means thatExchange Web Services tried to figure out what level of access the callerhas on the Free/Busy information of another account, but the access thatwas returned didn't make sense."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorInvalidSecurityDescriptor, new ResponseCodeInfo("The free/busy security descriptor is invalid.", "Indicates that the security descriptor on the calendar folder in the Store iscorrupt.Appendix A Response CodesAppendix A Response CodesErrorInvalidSendItemSaveSettingsMessage Invalid combination of SaveItemToFolder attribute and SavedItemFolderIdelement.Applicable methods SendItemThe SaveItemToFolder attribute is false, but you included aSavedItemFolderId."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorWin32InteropError, new ResponseCodeInfo("A Win32 function returned an error. The inner exception may have moredetails.", "Indicates that there was a failure when Exchange Web Services was talkingwith unmanaged code. Of course, you cannot see the inner exception becausethis is a SOAP response."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorWrongServerVersion, new ResponseCodeInfo("", ""));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorWrongServerVersionDelegate, new ResponseCodeInfo("", ""));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorProxyRequestNotAllowed, new ResponseCodeInfo("The request was found to be from a peer Availability Web service instance,but the requester does not have sufficient privileges.", "You will likely never encounter this response code. This response codeindicates that the request that Exchange Web Services sent to anotherCAS when trying to fulfill a GetUserAvailability request was invalid. Thisresponse code likely indicates a configuration or rights error, or someonetrying unsuccessfully to mimic an availability proxy request."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorProxyRequestProcessingFailed, new ResponseCodeInfo("Various messages depending on condition", "Exchange Web Services tried to proxy an availability request to anotherCAS for fulfillment, but the request failed. This could be due to issues suchas network connectivity or request timeoutAppendix A Response CodesAppendix A Response CodesErrorPublicFolderRequestProcessingFailedMessage {Error message}. The request information is {request}.Applicable methods GetUserAvailabilityThe recipient passed to GetUserAvailability is located on a legacyExchange server (prior to Exchange Server 2007). As such, ExchangeWeb Services needed to contact the public folder server to retrievefree/busy information for that recipient. Unfortunately, this call failed,resulting in Exchange Web Services returning a response code ofErrorPublicFolderRequestProcessingFailed."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorPublicFolderRequestProcessingFailed, new ResponseCodeInfo("{Error message}. The request information is {request}.", "The recipient passed to GetUserAvailability is located on a legacyExchange server (prior to Exchange Server 2007). As such, ExchangeWeb Services needed to contact the public folder server to retrievefree/busy information for that recipient. Unfortunately, this call failed,resulting in Exchange Web Services returning a response code ofErrorPublicFolderRequestProcessingFailed."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorWorkingHoursXmlMalformed, new ResponseCodeInfo("N/A", "You will never encounter this response code."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorServiceDiscoveryFailed, new ResponseCodeInfo("Various messages depending on error condition", "Exchange Web Services tried to proxy a user availability request to theappropriate Active Directory forest for the recipient in question, but itcould not determine where to send the request due to a service discoveryfailure."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorAddressSpaceNotFound, new ResponseCodeInfo("Configuration information for forest/domain {0} could not be found inActive Directory.", "The address space (Domain Name System [DNS] domain name) recordfor cross forest availability could not be found in the Microsoft ActiveDirectoryAppendix A Response CodesAppendix A Response CodesErrorADOperationMessage Active Directory operation did not succeed. Try again later.Applicable methods All methodsOperation failed due to issues talking with the Active Directory."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorAvailabilityConfigNotFound, new ResponseCodeInfo("Configuration information for the current forest or domain was not foundin the Active Directory.", "The availability configuration information for the local Active Directoryforest is missing from the Active Directory."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorInvalidCrossForestCredentials, new ResponseCodeInfo("This response code can be returned with two different error messages:Unable to send cross-forest request for mailbox {mailbox identifier}because of invalid configuration. When UseServiceAccount isfalse, user name cannot be null or empty.", "You should never encounter this response code"));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorInvalidFreeBusyViewType, new ResponseCodeInfo("The free/busy view type specified in the request is invalid.", "Returned if you call GetUserAvailability with a FreeBusyViewType of None"));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorTimeoutExpired, new ResponseCodeInfo("Request could not be processed in time. Timeout occurred during '{stateof current processing}'.", "The current request timed out."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorMissingArgument, new ResponseCodeInfo("You must specify {missing argument name}.", "A required argument was missing from the request. The response messagetext indicates which argument to check."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorNoCalendar, new ResponseCodeInfo("The target user does not have a calendar.", "There was no calendar folder for the Mailbox in question."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorInvalidAuthorizationContext, new ResponseCodeInfo("The request contains an invalid authorization context.", "You should not encounter this error, which has to do with a failure toproxy an availability request to another CAS"));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorLogonAsNetworkServiceFailed, new ResponseCodeInfo("Unable to logon as network service.", "Indicates that the availability service was unable to log on as NetworkService to proxy requests to the appropriate sites/forests. This typicallyindicates a configuration error."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorInvalidNetworkServiceContext, new ResponseCodeInfo("The acquired network service context has invalid identity.", "Indicates that there is a problem with the NetworkService account on theCAS. This response code is quite rare and has been seen only in the wildby the most vigilant of hunters."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorInvalidSmtpAddress, new ResponseCodeInfo("The SMTP address format is invalid.", "The passed in SMTP address is not parsable."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorIndividualMailboxLimitReached, new ResponseCodeInfo("Mailbox {mailbox name} could not be processed because the service alreadyprocessed {count of mailboxes already processed} individual mailboxes.", "Your request contained too many attendees to resolve. The default mailboxcount limit is 100."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorNoFreeBusyAccess, new ResponseCodeInfo("Caller does not have access to free busy data.", "Indicates that the caller does not have free/busy viewing rights on the calendarfolder in question."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorAutoDiscoverFailed, new ResponseCodeInfo("Depends on failure reason; various messages", "Indicates that Exchange Web Services tried to determine the URL of a crossforest Client Access Server (CAS) by using the AutoDiscover service, butthe call to AutoDiscover failed."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorMeetingSuggestionGenerationFailed, new ResponseCodeInfo("Various error messages depending on context.", "Indicates that the suggestions engine encountered a problem when it wastrying to generate the suggestions."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorFreeBusyGenerationFailed, new ResponseCodeInfo("Depends on failure; various messages", "Unable to retrieve Free/Busy information.This should not be common."));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorFreeBusyDLLimitReached, new ResponseCodeInfo("", ""));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorMissingInformationSharingFolderId, new ResponseCodeInfo("", ""));
            this.ResponseCodeDictionary.Add(ServiceError.ErrorDuplicateSOAPHeader, new ResponseCodeInfo("", ""));

        }

        #endregion
    }
}
